function depsets = findAllLinDepComb(w, wcols, maxsize)
    depsets = containers.Map('KeyType', 'int32', 'ValueType', 'any');
    ii = 1;
    ncols = min(length(wcols), maxsize);
    for i = 2:ncols
        ssets = combntns(wcols,i);
        for j = 1:size(ssets,1);
            cursset = ssets(j,:);
            wsset = w(cursset, :);
            sz = min( size(wsset) );
            rk = rank( wsset );
            if rk == (sz - 1);
                depsets(ii) = (cursset);
                %disp(cursset);
                ii = ii + 1;
            end            
        end
        disp(i);
    end
end